package com.yys.gulimall.ware.vo;

import lombok.Data;

import java.math.BigDecimal;
import java.util.List;

/**
 * @author zq
 * @version 1.0
 * @date 2021/4/3 14:33
 */
@Data
public class OrderItemVo {
    private Long skuId;
    private String title;
    private String image;
    private List<String> skuAttr;
    private BigDecimal price;
    private Integer count;
    private BigDecimal totalPrice;

    //TODO 重量
    private BigDecimal weight;

    public BigDecimal getTotalPrice() {
        // 计算商品总价
        return this.price.multiply(new BigDecimal("" + this.count));
    }

}
